﻿import request from '/@/utils/request';
enum Api {
  AddIotcategory = '/api/iotcategory/add',
  DeleteIotcategory = '/api/iotcategory/delete',
  UpdateIotcategory = '/api/iotcategory/update',
  PageIotcategory = '/api/iotcategory/page',
  DetailIotcategory = '/api/iotcategory/detail',
}

// 增加产品分类
export const addIotcategory = (params?: any) =>
	request({
		url: Api.AddIotcategory,
		method: 'post',
		data: params,
	});

// 删除产品分类
export const deleteIotcategory = (params?: any) => 
	request({
			url: Api.DeleteIotcategory,
			method: 'post',
			data: params,
		});

// 编辑产品分类
export const updateIotcategory = (params?: any) => 
	request({
			url: Api.UpdateIotcategory,
			method: 'post',
			data: params,
		});

// 分页查询产品分类
export const pageIotcategory = (params?: any) => 
	request({
			url: Api.PageIotcategory,
			method: 'post',
			data: params,
		});

// 详情产品分类
export const detailIotcategory = (id: any) => 
	request({
			url: Api.DetailIotcategory,
			method: 'get',
			data: { id },
		});


